/**
 * Created by leiqr on 2015/6/30.
 */
define(function (require, exports, module) {
    var $ = require('jquery');
    var login = require('./login');
   var dialog =  require('dialog');
    var d = dialog({
        title: '',
        width:'',
        content: '<div><p style="font-size: 16px;text-align: center;">朋友，敢问何许人也哦~</p><p style="font-size:16px;padding-top: 20px;text-align: center;"><a href="javascript:;" id="mysoft" style="padding: 50px; display: inline-block; color: #ff611d; cursor: pointer"><img src="/images/select1.png" style="padding-bottom: 10px;"><br>我是明源人</a><a style="padding: 50px; display: inline-block;color: #009cff;cursor: pointer" href="javascript:;" id="customer" ><img src="/images/select2.png" style="padding-bottom: 10px;"><br>我是客户</a></p></div>',
        cancel: false,
        ok:false,
        onshow: function(){
            $("#mysoft").click(function(e){
                d.close();
                login.dialog.showModal();
            });
            $('#customer').click(function(e){
                location.href = api_domain + '/login.shtml?ret_url='+ encodeURIComponent(location.href);
            });
            
        }
        // okValue: '我知道了',
        // ok: function () {
        //     location.href = 'http://qmyxcg.myscrm.com.cn/login.shtml?ret_url='+location.href;
        //     return false;
        // },
    });
    exports.dialog = d;
});
